package com.edushare.common.vo;

import com.edushare.common.vo.auto._UserRoles;

public class UserRoles extends _UserRoles {

	private static final long serialVersionUID = 5455745670496910182L;
	
	public static final int ADMIN_ROLE                  = 10;
	public static final int TEACHER_ROLE                = 20;
	public static final int STUDENT_ROLE                = 30;
	
	public static final int STATUS_INVITED               = 110;
	public static final int STATUS_ACTIVE                = 120;
	public static final int STATUS_REMOVED               = 130;
	
	@Override
	public void setUnivUniqId(String s){
		super.setUnivUniqId(s.trim());
	}
	
	public static String getRoleAsString(Integer roleType) {
		if(roleType == ADMIN_ROLE){
			return "Administrator";
		}else if(roleType == TEACHER_ROLE){
			return "Faculty";
		}else if(roleType == STUDENT_ROLE){
			return "Student";
		}else {
			return null;
		}
	}
}
